import Vue from 'vue';
import App from './App.vue';
import router from './router/index';
import store from './store/index';
import '@/styles/index.scss'; // global css

Vue.config.productionTip = false;

// 挂载主项目的 store 实例
(Vue.__share_pool__ = Vue.__share_pool__ || {}).store = store;

console.log(store);

router.beforeEach((to, form, next) => {
  // 认证拦截，通过config.userName判断是否为注册用户
  // console.log('路由', to, form);
  next();
});
new Vue({
  router,
  store,
  render: function(h) {
    return h(App);
  },
}).$mount('#app');
